<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" %>
<%
    String path = request.getContextPath();
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>数据管理</title>
    <link rel="shortcut icon" href="favicon.ico"> 
    <link href="${pageContext.request.contextPath}/hplus/css/bootstrap.min14ed.css?v=3.3.6" rel="stylesheet">
    <link href="${pageContext.request.contextPath}/hplus/css/font-awesome.min93e3.css?v=4.4.0" rel="stylesheet">
    <link href="${pageContext.request.contextPath}/hplus/css/plugins/iCheck/custom.css" rel="stylesheet">
    <link href="${pageContext.request.contextPath}/hplus/css/plugins/footable/footable.core.css" rel="stylesheet">
    <link rel="stylesheet" type="text/css" href="https://cdnjs.cloudflare.com/ajax/libs/datatables/1.10.16/css/jquery.dataTables.min.css" rel="stylesheet">
    <link href="${pageContext.request.contextPath}/hplus/css/animate.min.css" rel="stylesheet">
    <link href="${pageContext.request.contextPath}/hplus/css/style.min862f.css?v=4.1.0" rel="stylesheet">
    <link href="${pageContext.request.contextPath}/hplus/css/plugins/chosen/chosen.css" rel="stylesheet">
    <link href="${pageContext.request.contextPath}/hplus/css/plugins/colorpicker/css/bootstrap-colorpicker.min.css" rel="stylesheet">
    <link href="${pageContext.request.contextPath}/hplus/css/plugins/cropper/cropper.min.css" rel="stylesheet">
    <link href="${pageContext.request.contextPath}/hplus/css/plugins/switchery/switchery.css" rel="stylesheet">
    <link href="${pageContext.request.contextPath}/hplus/css/plugins/jasny/jasny-bootstrap.min.css" rel="stylesheet">
    <link href="${pageContext.request.contextPath}/hplus/css/plugins/nouslider/jquery.nouislider.css" rel="stylesheet">
    <link href="${pageContext.request.contextPath}/hplus/css/plugins/datapicker/datepicker3.css" rel="stylesheet">
    <link href="${pageContext.request.contextPath}/hplus/css/plugins/ionRangeSlider/ion.rangeSlider.css" rel="stylesheet">
    <link href="${pageContext.request.contextPath}/hplus/css/plugins/ionRangeSlider/ion.rangeSlider.skinFlat.css" rel="stylesheet">
    <link href="${pageContext.request.contextPath}/hplus/css/plugins/awesome-bootstrap-checkbox/awesome-bootstrap-checkbox.css" rel="stylesheet">
    <link href="${pageContext.request.contextPath}/hplus/css/plugins/clockpicker/clockpicker.css" rel="stylesheet">
    <link href="${pageContext.request.contextPath}/hplus/css/k_style.css" rel="stylesheet">
    <!-- 弹窗样式 -->
    <link rel="stylesheet" type="text/css" href="${pageContext.request.contextPath}/hplus/js/plugins/sweetalert/sweetalert2.min.css">
    <style> 
        .table{
            margin-top: 30px;
        }
        .my_class{
            width: 100px;
        }
        .s_form .col-sm-1 {
            padding-right: 0;
            padding-left: 0;
        }
        .icheckbox_square-green{
            position: relative;
        }
        .icheckbox_square-green checkbox{
            position: absolute;
            opacity: 0;
        }
        .iCheck-helper{
            position: absolute;
            top: 0%; 
            left: 0%; 
            display: block; 
            width: 100%;
            height: 100%;
            margin: 0px;
            padding: 0px;
            background: rgb(255, 255, 255);
            border: 0px; 
            opacity: 0;
        }
        .form-horizontal .control-label{
            text-align: left;
        }
        .checkbox{
            padding: 0;
        }
        .s_form{
            padding: 10px;
        }
        .s_btn_right{
            margin: 0;
        }
        th, td { white-space: nowrap; }
        
       #myTable{  
	    width: 100% !important;  
		}  
    </style>
</head>

<body class="gray-bg">
    <div class="wrapper wrapper-content">
        <div class="">
            <div class="tabs-container">
                <ul class="nav nav-tabs">
                    <li class="active"><a data-toggle="tab" href="#tab-1" aria-expanded="true"> 会员基本信息</a>
                    </li>
                    <!-- 
                    <li class=""><a data-toggle="tab" href="#tab-2" aria-expanded="false">会员级别</a>
                    </li>
                     <li class=""><a data-toggle="tab" href="#tab-3" aria-expanded="false">标签库</a>
                    </li>
                    <li class=""><a data-toggle="tab" href="#tab-4" aria-expanded="false">客户分组</a>
                    </li>
                    <li class=""><a data-toggle="tab" href="#tab-5" aria-expanded="false">积分使用记录</a>
                    </li>
                     -->
                </ul>
                <div class="tab-content">
                    <div id="tab-1" class="tab-pane active">
                        <div class="panel-body">
                            <form class="form-horizontal">
                                <div class="col-sm-2" style="height:30px;width:200px;line-height:30px;">会员基本信息：<span class="text-navy" style="font-size:26px;" id="hyCount"></span>条</div>
                                <div class="col-sm-1"></div>							
                                <div class="col-sm-1" style="height:30px;line-height:30px;width:100px;">导入时间</div>
                                <div class="form-group col-sm-3" id="data_5">				
                                    <div class="input-daterange input-group" id="datepicker">
                                        <input type="text" class="input-sm form-control" name="start" value="" id="startTime" onchange="searchData();"/>
                                        <span class="input-group-addon">到</span>
                                        <input type="text" class="input-sm form-control" name="end" value="" id="endTime" onchange="searchData();"/>
                                    </div>
                                </div>       					
                                <div class="col-sm-2"></div>        
                                <div class="col-sm-3">
                                    <div class="input-group">
                                        <input type="text" placeholder="填写手机号或姓名进行查找" style="width:195px;" class="input form-control" id="phoneAndName">
                                        <span class="input-group-btn">								
                                            <button type="button" class="btn btn btn-primary" onclick="searchData();"> <i class="fa fa-search"></i> 搜索</button>
                                        </span>
                                    </div>			
                                </div>								
                            </form>					
                        </div>
                    </div>
                    <div id="tab-2" class="tab-pane">
                        <div class="panel-body">
                            会员级别
                        </div>
                    </div>
                    <div id="tab-3" class="tab-pane">
                        <div class="panel-body">
                            标签库
                        </div>
                    </div>
                    <div id="tab-4" class="tab-pane">
                        <div class="panel-body">
                            客户分组
                        </div>
                    </div>
                    <div id="tab-5" class="tab-pane">
                        <div class="panel-body">
                            积分使用记录
                        </div>
                    </div>
                </div>
            </div>
        </div>

        <div class="ibox-content col-sm-12" style="margin:20px 0 0 0px;">
            <span>会员基本信息</span>
            <div class="s_btn_right" style="float:right;margin:0 0 10px 0px;" >
                <button class="btn btn-primary btn-outline" type="button" data-toggle="modal" data-target="#myModal">数据显示</button>
                <button class="btn btn-primary" type="button" data-toggle="modal" data-target="#myModa2">数据回溯</button>
                <button class="btn btn-primary" type="button" onclick="importMeatch();">导入</button>
            </div>
   		<div class="ibox-content" style="margin:10px 0 0 0px;">
        <table class="display  table-striped table-bordered table-hover" id="myTable">
            <thead>
            <tr>
                <th>会员ID</th>
                <th>会员姓名</th>
                <th>居住地址</th>
                <th>办公地址</th>
                <th>性别</th>
                <th>身份证</th>
                <th>收入区间</th>
                <th>家庭人数</th>
                <th>学历</th>
                <th>年龄段</th>
                <th>子女姓名</th>
                <th>子女年龄</th>
                <th>家中老人</th>
                <th>老人年龄</th>
                <th>手机</th>
                <th>邮箱</th>
                <th>微信号</th>
                <th>微博号</th>
                <th>QQ号</th>
                <th>现有积分</th>
                <th>历史积分</th>
                <th>会员等级</th>
                <th>酷币</th>
                <th>渠道来源</th>
                <th>所属销售</th>
                <th>推荐人</th>
                <th>所属门店</th>
                <th>价值评分</th>
                <th>会员分类</th>
                <th>会员分组</th>
                <th>入会日期</th>
                <th>购买次数</th>
                <th>购买总额</th>
                <th>购买总件数</th>
                <th>标签</th>
                <th>最后购买时间</th>
                <th>最后次购买金额</th>
                <th>首次购买时间</th>
                <th>首次购买金额</th>
            </tr>				
            </thead>		
        </table>
    </div>
        </div>      		
    </div>

    <!-- 数据显示弹框 -->
    <div class="modal inmodal in" id="myModal" tabindex="-1" role="dialog" aria-hidden="true">
        <div class="modal-dialog">
            <div class="modal-content animated bounceInRight">
                <div class="modal-header" style="padding: 15px 15px 10px;">
                    <button type="button" class="close" data-dismiss="modal" ><span aria-hidden="true">&times;</span><span class="sr-only" >Close</span></button>
                    <h4 class="text-left">数据显示</h4>
                </div>				
                <small class="font-bold">
                    <form method="get" class="form-horizontal s_form">
                        <div class="form-group">
                            <p class="col-sm-12 control-label">会员基本信息</p>
                            <div class="col-sm-12">
                                <div class="checkbox i-checks">
                                    <label class=""  id="memberId" >
                                        <div class="icheckbox_square-green"><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> <span>会员ID</span>
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class="" id="name">
                                        <div class="icheckbox_square-green" ><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 会员姓名
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class="" id="address">
                                        <div class="icheckbox_square-green" ><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 居住地址
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class="" id="office_address">
                                        <div class="icheckbox_square-green" ><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 办公地址
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class="" id="gender">
                                        <div class="icheckbox_square-green" ><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 性别
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class="" id="id_card">
                                        <div class="icheckbox_square-green" ><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 身份证
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class="" id="income_range">
                                        <div class="icheckbox_square-green" ><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 收入区间
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class="" id="family_size">
                                        <div class="icheckbox_square-green" ><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 家庭人数
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class="" id="education">
                                        <div class="icheckbox_square-green" ><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 学历
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class="" id="age_bracket">
                                        <div class="icheckbox_square-green" ><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 年龄段
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class="" id="children_name">
                                        <div class="icheckbox_square-green" ><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 子女姓名
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class="" id="children_age">
                                        <div class="icheckbox_square-green" ><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 子女年龄
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class="" id="parent_name">
                                        <div class="icheckbox_square-green" ><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 家中老人
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class="" id="parent_age">
                                        <div class="icheckbox_square-green" ><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 老人年龄
                                    </label>
                                </div>
                            </div>
                        </div>
                        <div class="form-group">
                            <p class="col-sm-12 control-label">联系方式</p>
                            <div class="col-sm-12">
                                <div class="checkbox i-checks">
                                    <label class="" id="phone">
                                        <div class="icheckbox_square-green" ><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 手机
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class="" id="email">
                                        <div class="icheckbox_square-green" ><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 邮箱
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class="" id="wechat">
                                        <div class="icheckbox_square-green" ><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 微信号
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class="" id="weibo">
                                        <div class="icheckbox_square-green" ><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 微博号
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class="" id="QQ">
                                        <div class="icheckbox_square-green" ><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i>QQ号
                                    </label>
                                </div>
                            </div>
                        </div>
                        <div class="form-group">
                            <p class="col-sm-12 control-label">会员等级</p>
                            <div class="col-sm-12">
                                <div class="checkbox i-checks">
                                    <label class="" id="crmScore">
                                        <div class="icheckbox_square-green"><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 现有积分
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class="" id="crm_his_score">
                                        <div class="icheckbox_square-green"><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 历史积分
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class="" id="level">
                                        <div class="icheckbox_square-green"><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i>会员等级
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class="" id="cool_coin">
                                        <div class="icheckbox_square-green"><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i>酷币
                                    </label>
                                </div>
                            </div>
                        </div>
                        <div class="form-group">
                            <p class="col-sm-12 control-label">会员来源</p>
                            <div class="col-sm-12">
                                <div class="checkbox i-checks">
                                    <label class="" id="source">
                                        <div class="icheckbox_square-green"><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 渠道来源
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class="" id="belong_saleper">
                                        <div class="icheckbox_square-green"><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 所属销售
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class="" id="referee">
                                        <div class="icheckbox_square-green"><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 推荐人
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class="" id="store_name">
                                        <div class="icheckbox_square-green"><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 所属门店
                                    </label>
                                </div>
                            </div>
                        </div>
                        <div class="form-group">
                            <p class="col-sm-12 control-label">会员管理</p>
                            <div class="col-sm-12">
                                <div class="checkbox i-checks">
                                    <label class="" id="value_score">
                                        <div class="icheckbox_square-green"><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 价值评分
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class="" id="type_customer">
                                        <div class="icheckbox_square-green"><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 会员分类
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class="" id="group_customer">
                                        <div class="icheckbox_square-green"><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 会员分组
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class="" id="create_time">
                                        <div class="icheckbox_square-green"><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 入会日期
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class="" id="cost_count">
                                        <div class="icheckbox_square-green"><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 购买次数
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class="" id="cost_total">
                                        <div class="icheckbox_square-green"><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i>购买总额
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class="" id="goods_total">
                                        <div class="icheckbox_square-green"><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i>购买总件数
                                    </label>
                                </div>
                                <!--  
                                <div class="checkbox i-checks">
                                    <label class="">
                                        <div class="icheckbox_square-green"><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i>价值评分
                                    </label>
                                </div>
                                -->
                            </div>
                        </div>
                        <div class="form-group">
                            <p class="col-sm-12 control-label">会员标签</p>
                            <div class="col-sm-12">
                                <div class="checkbox i-checks">
                                    <label class=""  id="tag">
                                        <div class="icheckbox_square-green"><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 标签
                                    </label>
                                </div>
                            </div>
                        </div>
                        <div class="form-group">
                            <p class="col-sm-12 control-label">交易信息</p>
                            <div class="col-sm-12">
                                <div class="checkbox i-checks">
                                    <label class="" id="last_cost_time">
                                        <div class="icheckbox_square-green"><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 最后次购买时间
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class="" id="last_cost">
                                        <div class="icheckbox_square-green"><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 最后次购买金额
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class="" id="first_cost_time">
                                        <div class="icheckbox_square-green"><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 首次购买时间
                                    </label>
                                </div>
                                <div class="checkbox i-checks">
                                    <label class=""  id="first_cost">
                                        <div class="icheckbox_square-green"><input type="checkbox"><ins class="iCheck-helper"></ins></div><i></i> 首次购买金额
                                    </label>
                                </div>

                            </div>
                        </div>
                        
                    </form>
                    <div class="modal-footer">
                        <button type="button" class="btn btn-white" data-dismiss="modal">关闭</button>
                        <button type="button" class="btn btn-primary" data-dismiss="modal" onclick="userClickTab();" >确定</button>
                    </div>
                </small>
            </div>
            <small class="font-bold"></small>
        </div>
        <small class="font-bold"></small>
    </div>
    <!-- 数据回溯弹框 -->
    <div hidden="" class="modal inmodal fade" id="myModa2" tabindex="-1" role="dialog" aria-hidden="true">
        <div class="modal-dialog modal-sm">
            <div class="modal-content">
                <div class="modal-header" style="padding: 15px 15px 10px;">
                    <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
                    <h4 class="text-left">数据回溯</h4>
                </div>
                <div class="text-center" style="width:100%;height:60px;">                    
                    <form method="get" class="form-horizontal col-sm-12" style="margin:20px 0;">
                        <div class="form-group">
                            <p>选择时间点后，平台内导入数据将回溯至所选时间状态，确定回溯吗？</p>
                        </div>
                        <div class="form-group">
                            <label class="col-sm-5 control-label" style="text-align:right;">请选择回溯的时间节点</label>
                            <div class="col-sm-6">
                                <select id="hsSelect" class="form-control" name="account">
                                </select>
                            </div>
                        </div>
                    </form>
                </div>
                 <div class="modal-footer" style="text-align:center;border-top:none;">
                     <button type="button" class="btn btn-outline btn-primary" data-dismiss="modal">关闭</button>
                     <button type="button" class="btn btn-primary k_verify" onclick="hsUpdate();">确定</button>
                 </div>
             </div>
        </div>
    </div>

    <!-- 数据导入弹框 -->
    <div hidden="" class="modal inmodal fade" id="myModa3" tabindex="-1" role="dialog" aria-hidden="true">
        <div class="modal-dialog modal-sm">
            <div class="modal-content">
                <div class="modal-header" style="padding: 15px 15px 10px;">
                    <button type="button" class="close" onclick = "closeTabReload();"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
                    <h4 class="text-left">数据导入</h4>
                </div>
                <div class="text-center">                    
                    <form method="get" class="form-horizontal col-sm-12" style="margin:20px 0;">
                        <div class="form-group">
                            <p>请<span class="text-navy"><a href="<%=path%>/scan/member/downExportTemplate">下载导入模板</a></span>后，根据模板格式填写数据，并进行导入</p>
                        </div>
                        <img src="${pageContext.request.contextPath}/hplus/img/sjdr.png" style="cursor:pointer;" onclick="fileSelect();"/>
                        <span id="filePath"></span>		
             		  <div class="text-center">
                	    <input class="col-sm-3" id="file" type="file" name="file" onchange="fileSelected();" style="display:none;">
               		 </div>		
                    </form>
                </div>			
            
                <div class="text-center">
                	<button type="button" class="btn btn-primary k_verify" onclick="fileSelect();" >导入数据</button>
                </div>			
                <div class="text-center">						
                	<span id="importAlertSpan" style="color:red;display:none;">请选择需要导入的excel</span>
                </div>		
                <div class="text-center">						
                	<span id="closeRuleAlert" style="color:red;display:none;">数据导入中请勿关闭弹窗</span>
                </div>		
                
                <div class="form-group" style="padding: 20px 0 50px;display:none;" id="exportPro">		
                    <label class="col-sm-3 control-label" style="text-align:right;">正在导入</label>										
                    <div class="col-sm-8" style="margin-top:6px;">
                        <div class="progress progress-striped active" style="height:8px;">
                            <div style="width: 100%;height:8px;" aria-valuemax="70" aria-valuemin="0" aria-valuenow="70" role="progressbar" class="progress-bar">
                            </div>			
                        </div>			
                    </div>								
                </div>			
                <div class="form-group text-center" id="successShow" style="display:none;">
                    <p>已成功导入<span class="text-navy" id="sucNums" ></span>条用户信息，其中<span id="errNums"></span>条数据无法使用请<span class="text-navy" style="cursor:pointer;" onclick="exportError();">导出</span>查看</p>
                </div>
                <div class="form-group text-center" id="errorShow" style="display:none;">
                    <p><span style="color:red;">导入的会员数据不能超过3000条，请核对*</span></p>
                </div>
                <div class="modal-footer" style="text-align:center;border-top:none;">
                     <button type="button" class="btn btn-outline btn-primary" onclick = "closeTabReload();">关闭</button>
                     <button type="button" class="btn btn-primary k_verify" id="submit" onclick="qdAlert();">确定</button>
                 </div>
             </div>
        </div>
    </div>
    
	<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/2.2.4/jquery.min.js"></script>
    <!-- <script src="${pageContext.request.contextPath}/hplus/js/jquery.min.js?v=2.1.4"></script> -->
    <!-- <script src="${pageContext.request.contextPath}/hplus/js/bootstrap.min.js?v=3.3.6"></script> -->
    <script src="https://cdn.jsdelivr.net/gh/bootcdn/BootCDN/ajax/libs/bootstrap/3.3.7/js/bootstrap.min.js"></script>
    <script src="${pageContext.request.contextPath}/hplus/js/content.min.js?v=1.0.0"></script>
    <script src="${pageContext.request.contextPath}/hplus/js/plugins/footable/footable.all.min.js"></script>
    <script src="${pageContext.request.contextPath}/hplus/js/plugins/datapicker/bootstrap-datepicker.js"></script>
	<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/datatables/1.10.16/js/jquery.dataTables.min.js"></script>
    <script src="${pageContext.request.contextPath}/hplus/js/plugins/iCheck/icheck.min.js"></script>
    <script src="${pageContext.request.contextPath}/js/system/jquery.ui.widget.js"></script>
    <script src="${pageContext.request.contextPath}/js/system/jquery.fileupload.js"></script>				
    <!-- <script src="${pageContext.request.contextPath}/b_js/jquery.cookie.js"></script> -->
    <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery-cookie/1.4.1/jquery.cookie.min.js"></script>
    <!-- 弹窗插件 -->
	<script src="${pageContext.request.contextPath}/hplus/js/plugins/sweetalert/sweetalert2.min.js"></script>

    <script>
        $(document).ready(function(){$(".i-checks").iCheck({checkboxClass:"icheckbox_square-green",radioClass:"iradio_square-green",})});

        //$(document).ready(function() {
        //    var table = $(".dataTables-example").dataTable({
        //        "scrollX": true,
        //        "ordering": false,
        //        "columnDefs": [
                    //给第一列指定宽度为表格整个宽度的 10px
        //            { "width": "180px", "targets": [2,3] },
        //            { "width": "70px", "targets": [1,6,7,9,10,11,12,13,19,20,21,22,23,24,25,26,27] },
        //            { "width": "40px", "targets": [4,8] }],
        //        "searching": false,
        //        "lengthChange": false
        //   });
        //});
        
        
        var path = "<%=path%>";
        //表格控件
        var myDataTable;
        
        $(function () {			
       	//初始化日期选择框
       	//$("#data_5 .input-daterange").datepicker({keyboardNavigation: !1, forceParse: !1, autoclose: !0});
       	//$("#data_6 .input-daterange").datepicker({keyboardNavigation: !1, forceParse: !1, autoclose: !0});
           	 
       	$("#startTime").datepicker({autoclose : true, endDate:new Date()});
     	$("#endTime").datepicker({autoclose : true, endDate:new Date()});							
       	//$('#startTime').datepicker({ 
		//todayBtn : "linked", 
		//autoclose : true, 
		//todayHighlight : true, 
		//endDate : new Date() 
		//}).on('changeDate',function(e){ 
		//var startTime = e.date; 		
		//$('#startTime').datepicker('setStartDate',startTime); 
		//}); 
		//结束时间： 
		//$('#endTime').datepicker({ 
		//todayBtn : "linked", 
		//autoclose : true, 
		//todayHighlight : true, 
		//endDate : new Date() 
		//}).on('changeDate',function(e){ 
		//var endTime = e.date; 
		//$('#endTime').datepicker('setEndDate',endTime); 
		//});
				
       	 myDataTable = dataTable();					
       	 $('input').iCheck('check');
       	 //动态控制页面上的列
		 initDt();
         
        });
        
        //存储用户的点击和选择行为
        function qcResult(id){
        	if(userClickRow.length != 0){
        		var tag = 0;			
            	for(var i=0;i<userClickRow.length;i++){
            		if(userClickRow[i] == id){
            			tag = 1;			
            			break;
            		}
            	}
            	if(tag != 1){
            	userClickRow.push(id);
            	}else{
            	var newArr = [];
            	for(var o=0;o<userClickRow.length;o++){
            		if(userClickRow[o] != id){
            			newArr.push(userClickRow[o]);
            		}
            	}
            	userClickRow = newArr;
            	}
        	}else{
        		userClickRow.push(id);
        	}
        }
        
        //showhidmeatch
        var userClickRow = []; //用户选中的
        var userClickRowAll = []; //用户全部的 
        var userNoClickRow = []; //用户未选中的
   		 //动态控制页面上的列		
        function initDt(){
   			 //初始化用户选择的列
   			 for(var i=0;i<39;i++){
   				userClickRow.push(i);
   				userClickRowAll.push(i);
   			 }
   			 
   			 
             $('#memberId').on( 'click', function (){qcResult(0)});
             $('#name').on( 'click', function (){qcResult(1)});						
             $('#address').on( 'click', function (){qcResult(2)});
             $('#office_address').on( 'click', function (){qcResult(3)});
             $('#gender').on( 'click', function (){qcResult(4)});
             $('#id_card').on( 'click', function (){qcResult(5)});
             $('#income_range').on( 'click', function (){qcResult(6)});
             $('#family_size').on( 'click', function (){qcResult(7)});
             $('#education').on( 'click', function (){qcResult(8)});
             $('#age_bracket').on( 'click', function (){qcResult(9)});
             $('#children_name').on( 'click', function (){qcResult(10)});
             $('#children_age').on( 'click', function (){qcResult(11)});
             $('#parent_name').on( 'click', function (){qcResult(12)});
             $('#parent_age').on( 'click', function (){qcResult(13)});
             $('#phone').on( 'click', function (){qcResult(14)});
             $('#email').on( 'click', function (){qcResult(15)});
             $('#wechat').on( 'click', function (){qcResult(16)});
             $('#weibo').on( 'click', function (){qcResult(17)});
             $('#QQ').on( 'click', function (){qcResult(18)});
             $('#crmScore').on( 'click', function (){qcResult(19)});
             $('#crm_his_score').on( 'click', function (){qcResult(20)});
             $('#level').on( 'click', function (){qcResult(21)});
             $('#source').on( 'click', function (){qcResult(22)});
             $('#cool_coin').on( 'click', function (){qcResult(23)});
             $('#belong_saleper').on( 'click', function (){qcResult(24)});
             $('#referee').on( 'click', function (){qcResult(25)});
             $('#store_name').on( 'click', function (){qcResult(26)});
             $('#value_score').on( 'click', function (){qcResult(27)});
             $('#type_customer').on( 'click', function (){qcResult(28)});
             $('#group_customer').on( 'click', function (){qcResult(29)});
             $('#create_time').on( 'click', function (){qcResult(30)});
             $('#cost_count').on( 'click', function (){qcResult(31)});
             $('#cost_total').on( 'click', function (){qcResult(32)});
             $('#goods_total').on( 'click', function (){qcResult(33)});
             $('#tag').on( 'click', function (){qcResult(34)});
             $('#last_cost_time').on( 'click', function (){qcResult(35)});
             $('#last_cost').on( 'click', function (){qcResult(36)});
             $('#first_cost_time').on( 'click', function (){qcResult(37)});
             $('#first_cost').on( 'click', function (){qcResult(38)});
        }
   		 //根据列id控制显示和隐藏
   		 function showhidmeatch(){
   			var table = $('#myTable').DataTable();
   			//先全部隐藏
   			for(var i=0;i<userClickRowAll.length;i++){
   	            var column = table.column(userClickRowAll[i]);
   	            //alert(!column.visible());
   	            column.visible(false);				
   			}
   			//再对指定列展示
   			for(var i=0;i<userClickRow.length;i++){
   	            var column = table.column(userClickRow[i]);
   	            //alert(!column.visible());
   	            column.visible(true);				
   			}
            func_dataTableReload();
            swal("操作成功！", "", "success"); 
   		 }
        
        
        
        //表格刷新
        function func_dataTableReload() {
            myDataTable.ajax.reload();
        }
        
        //初始化表格控件
        function dataTable() {
            return $('#myTable').DataTable({
                processing: true,
                ordering: false,
                searching: false,
                info: true,
                autoWidth: true,
                lengthChange: false,
                scrollX: true,
                language: {
                    emptyTable: '没有数据表',
                    info: '从第 _START_ 到第 _END_ 条数据；总共有 _TOTAL_ 条记录',
                    infoEmpty: '没有数据',
                    lengthMenu: '每页显示 _MENU_ 条记录',
                    loadingRecords: '正在加载数据....',
                    processing: '<br/>正在处理数据....',
                    zeroRecords: '没有找到匹配的记录',
                    paginate: {
                        first: '首页',
                        previous: '前页',
                        next: '后页',
                        last: '尾页'
                    }
                },
                order: [[1, 'desc']],
                pageLength: 10,
                pagingType: 'full_numbers',
                columnDefs: [{
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {			
                        	  result = "——";
                    	}else{
                            if (data.length > 5) {
                                result = "<span title='" + data + "'>" + data.substr(0, 4) + "..</span>";
                            } else {
                                result = data;
                            }
                    	}				
                        return result;
                    },
                    targets: 1   //第一列
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;
                        }
                        return result;
                    },
                    targets: 2   //第二列		
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;
                        }
                        return result;
                    },
                    targets: 3 //第三列
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "" || data == "n") {
                            result = "未知";				
                        } else {
                        	if(data == "f"){
                        	result = "女";
                       		}else if(data == "m"){
                       		result = "男";	
                       		}
                        }
                        return result;
                    },
                    targets: 4
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;
                        }
                        return result;
                    },
                    targets: 5
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;
                        }
                        return result;
                    },
                    targets: 6
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;
                        }
                        return result;
                    },
                    targets: 7
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;
                        }
                        return result;
                    },
                    targets: 8
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;
                        }
                        return result;
                    },
                    targets: 9
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;
                        }
                        return result;
                    },
                    targets: 10
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;
                        }
                        return result;
                    },
                    targets: 11
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;
                        }
                        return result;
                    },
                    targets: 12
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;
                        }
                        return result;
                    },
                    targets: 13
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;
                        }
                        return result;
                    },
                    targets: 14
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;
                        }
                        return result;
                    },
                    targets: 15
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;
                        }
                        return result;
                    },
                    targets: 16
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;
                        }
                        return result;
                    },
                    targets: 17
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;				
                        }
                        return result;
                    },
                    targets: 18
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;				
                        }
                        return result;
                    },
                    targets: 19
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;				
                        }
                        return result;
                    },
                    targets: 20
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;				
                        }
                        return result;
                    },
                    targets: 21
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;				
                        }
                        return result;
                    },
                    targets: 22
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;				
                        }
                        return result;
                    },
                    targets: 23
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;				
                        }
                        return result;
                    },
                    targets: 24
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;				
                        }
                        return result;
                    },
                    targets: 25
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;				
                        }
                        return result;
                    },
                    targets: 26
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;				
                        }
                        return result;
                    },
                    targets: 27
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;				
                        }
                        return result;
                    },
                    targets: 28
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;				
                        }
                        return result;
                    },
                    targets: 29
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;				
                        }
                        return result;
                    },
                    targets: 30
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;				
                        }
                        return result;
                    },
                    targets: 31
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;				
                        }
                        return result;
                    },
                    targets: 32
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;				
                        }
                        return result;
                    },
                    targets: 33
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;				
                        }
                        return result;
                    },
                    targets: 34
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;				
                        }
                        return result;
                    },
                    targets: 35
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;				
                        }
                        return result;
                    },
                    targets: 36
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;				
                        }
                        return result;
                    },
                    targets: 37
                }, {
                    render: function (data, type, full) {
                        var result = "";
                        if (data == null || data == "") {
                            result = "——";
                        } else {
                            result = data;				
                        }
                        return result;
                    },
                    targets: 38
                }],		
                columns: func_columns(),
                serverSide: true,
                ajax: {
                    contentType: 'text/plain;charset=utf-8',
                    type: 'POST',
                    url: func_AjaxUrl(),
                    data: function (d) {
                        d.extra_search = func_ajaxData();
                        return JSON.stringify(d);
                    }
                }
            });
            
        }
        
        //向后台发送Ajax请求
        function func_AjaxUrl() {
            return path + "/member/ajaxMemberPageListForDataManage";
        }
        /**
         *	设置列名，对应后台
         */
        function func_columns() {
            var jsonArr = [
				{"data": "memberId"},           
				{"data": "name"},
				{"data": "address"},
				{"data": "office_address"},
				{"data": "gender"},
				{"data": "id_card"},
				{"data": "income_range"},
				{"data": "family_size"},
				{"data": "education"},
				{"data": "age_bracket"},
				{"data": "children_name"},
				{"data": "children_age"},
				{"data": "parent_name"},
				{"data": "parent_age"},
                {"data": "phone"},
                {"data": "email"},
                {"data": "wechat"},
                {"data": "weibo"},
                {"data": "QQ"},
                {"data": "crmScore"},
                {"data": "crm_his_score"},
                {"data": "crm_member_level"},
                {"data": "cool_coin"},
                {"data": "source"},
                {"data": "belong_saleper"},
                {"data": "referee"},
                {"data": "store_name"}, //该字段目前还暂无中间表，暂时维护在会员表，后续可能对其进行调整
                {"data": "value_score"},
                {"data": "type_customer"}, //会员分类
                {"data": "group_customer"},//会员分组
                {"data": "create_time"},
                {"data": "cost_count"},
                {"data": "cost_total"},
                {"data":"goods_total"},
                {"data": "tag"},
                {"data": "last_cost_time"},
                {"data": "last_cost"},
                {"data": "first_cost_time"},
                {"data": "first_cost"}
            ];
            return jsonArr;
        }
        
        
        function func_ajaxData() {
           var jsonObject = new Object();
           if ($.trim($("#phoneAndName").val()) != "") {
               jsonObject.phoneAndName = $("#phoneAndName").val();
           }
           		jsonObject.startTime = $("#startTime").val();
           		jsonObject.endTime = $("#endTime").val();
            return jsonObject;
           }
        
        function fileSelect() {
            document.getElementById("file").click();
            $("#submit").show();
        }
       
        function fileSelected() {
        	var pathFile = $("#file").val().replace(/\\/g, "/");
        	var total = pathFile.length;
        	var firTotal = pathFile.lastIndexOf("/");
          // 文件选择后触发次函数
          $("#filePath").text(pathFile.substring(firTotal + 1,total));
        }
        var errorList = "";
        //判断是否导入成功
        var drgc = 0;
        $(function(){
        	var type = 2; //1 重复数据覆盖、2 重复数据跳过
            //导出调用的路径
            var url = path+"/scan/member/importdataManage";		
            $(':file').fileupload({
//         		autoUpload: false,
        		replaceFileInput: false,
        		dataType: "json",
        		url : url,
//         		formData: {type: $(":radio[name='type']:checked").val()},
        		add: function(e,data){
        			$("#submit").click(function(){
        				if($("#filePath").text() != "" && $("#filePath").text() != null){
            				drgc = 1;
            			  	$("#importAlertSpan").hide();
            			  	$("#closeRuleAlert").hide();			
            				$("#exportPro").show();					
            				data.formData = {
            						type: type,
            						//name:name,
            						//parentId:parentId
            		            	cid : cid,
            		            	uid : uid,
            		            	access_token : access_token
            				}
            				data.submit();
        				}else{
        					$("#importAlertSpan").show();
        					$("#closeRuleAlert").hide();
        					$("#successShow").hide();
        					$("#errorShow").hide();
        				}

        			});
        		},
        		done : function(e,data) {
        			if(data.result.msg_code == 1){
        				drgc = 0;
        				$("#importAlertSpan").hide();
        			  	$("#closeRuleAlert").hide();
        				$("#sucNums").text(data.result.successImport);
        				$("#errNums").text(data.result.errorImport);
        				
        				//隐藏确定按钮
        				$("#submit").hide();
        				//errorList = data.result.listError;
        				if(data.result.errorImport == 0){
        					  window.location.reload();
        				}else{
            				$("#successShow").show();
            				$("#exportPro").hide();
            				$("#errorShow").hide();
        					func_dataTableReload();
        				}
        			}else if(data.result.msg_code == 3){
        				$("#errorShow").show();
        				$("#exportPro").hide();
        				$("#successShow").hide();
        			}
        		}
        	});
            
            //初始化回溯时间
            initHsTime();
            //初始化会员总数
            initHyCount();
            
        });
       
      var access_token=$.cookie('access_token');
   	  var cid=$.cookie('cid');
   	  var uid=$.cookie('uid');
	  //初始化回溯时间节点
      function initHsTime(){
		  
      	  $.ajax({
	            type: "POST",
	            async: false,
	            url: "${pageContext.request.contextPath}/scan/member/initHsTime",
	            data: {
	            	"cid" : cid,
	            	"uid" : uid,
	            	"access_token" : access_token
	            	},
	            dataType: "json",
	      	    timeout: 1000,
	            success: function(data){
	            	if(data.status == 200){
	            		var activeData = data.data;
	            		for(var i=0;i<activeData.length;i++){
		            	//alert(formatDate(activeData[i].export_time));
		       	     	$("<option  value='"+activeData[i].export_time+"' selected>"+activeData[i].export_time+"</option>").appendTo("#hsSelect");
	            		}
	            	}
	            }	
			});
      }
	  
	  //确定回溯
	  function hsUpdate(){
      	  $.ajax({
	            type: "POST",
	            async: false,
	            url: "${pageContext.request.contextPath}/scan/member/hsTimeNow",
	            data: {
	            	"cid" : cid,
	            	"uid" : uid,
	            	"access_token" : access_token,
	            	"hsTime":$("#hsSelect").val()
	            	},
	            dataType: "json",
	      	    timeout: 1000,
	            success: function(data){							
	            	if(data.status == 200){
	            		//回溯后执行的刷新逻辑
	            		window.location.reload();
	            	}
	            }	
			});
	  }
	  
	  //导出无法导入的会员信息
	  function exportError(){
		  //将未导入的数据传入服务端进行导出
		  //window.location.href=path+"/scan/member/exportListErrorForm?cid="+cid+"&uid="+uid+"&access_token="+access_token+"&errorList="+encodeURI(encodeURI(errorList));
		  //修改为从redis中获取导出失败的数据
		  window.location.href=path+"/scan/member/exportListErrorForm?cid="+cid+"&uid="+uid+"&access_token="+access_token;
	  }
	  
	  //初始化会员总数
	  function initHyCount(){
      	  $.ajax({
	            type: "POST",
	            async: false,
	            url: "${pageContext.request.contextPath}/scan/member/initHyCount",
	            data: {
	            	"cid" : cid,
	            	"uid" : uid,
	            	"access_token" : access_token
	            	},
	            dataType: "json",
	      	    timeout: 1000,
	            success: function(data){
	            	if(data.status == 200){
	            		var activeData = data.data;		
	            		$("#hyCount").text(activeData)
	            	}
	            }	
			});
	  }
	  
	  //搜索
	  function searchData(){
		  func_dataTableReload();				
	  }
	  
	  //点击导入时触发
	  function importMeatch(){
		  	drgc = 0;//导入成功状态置为0
		  	$("#submit").show();
		  	$("#importAlertSpan").hide();
		  	$("#closeRuleAlert").hide();
		     //$("#filePath").text(''); //清空文件路径
		     //$("#file").val(''); //清空选择文件路径
		     $("#successShow").hide(); //隐藏导出状态
		     $("#errorShow").hide(); //隐藏导出状态
	         //弹窗时，禁用模态框点击空白处或esc退出
	         $('#myModa3').modal({backdrop: 'static', keyboard: false});
	  }
	  
	  //动态控制dataTable隐藏或显示
	  function hideAndShow(){


	  }
	  
	  //关掉窗口并刷新
	  function closeTabReload(){
		  if(drgc == 0){
			  window.location.reload(); 
		  }else if(drgc == 1){
			 //$('#myModa3').modal('hide');  
			 // swal({title: "导入数据时请勿关闭此窗口",type: 'warning'}).then(function () {
			 //	 $('#myModa3').modal({backdrop: 'static', keyboard: false});
			 //	})
			 $("#closeRuleAlert").show();
		  }
	  }
	  
	  //关掉窗口不刷新
	  function userClickTab(){
	    	showhidmeatch();
	  }
	  
	  //确定弹窗提示
	  function qdAlert(){					
		  if($("#filePath").text() == ""){					
			  $("#importAlertSpan").show();
		  }
		  //else{
		  //  $("#importAlertSpan").hide();		
		  //}			
	  }
        					
	 
		  //隐藏第六列，从第0列开始;这里有所有的api： http://www.datatables.net/

    </script>
</body>
</html>
